const axios = require('axios')
const config = require('@/config/api.json')

const fetch = axios.create({
  baseURL: config.juejin.BASE_URL,
  timeout: 5000,
  headers: {
    'X-Agent': 'Juejin/Web',
    'User-Agent':
      'Mozilla/5.0 (iPhone; CPU iPhone OS 13_2_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/13.0.3 Mobile/15E148 Safari/604.1',
  },
})

module.exports = fetch
